<?php
	if(isset($gallery) && !empty($gallery) || isset($download_files) && !empty($download_files)){
		$width = 150;
      	foreach ($gallery as $key => $image){
       		if(is_numeric($key)){
				echo $this->Html->link('',$this->FileUpload->image($image['Upload']['name'],array('autoResize'=>true,'imagePathOnly'=>true,'imageNoSpacebar'=>true,'width'=>1024)),array('escape'=>false,'title'=>h($image['Upload']['description']),'class'=>"highslide",'style'=>"display: block; background: url('{$this->FileUpload->image($image['Upload']['name'],array('autoResize'=>true,'imagePathOnly'=>true,'imageNoSpacebar'=>true,'width'=>170))}') no-repeat center center; width: 150px; height: 110px; float: left; border-radius: 10px; margin: 0 18px 18px 18px;", 'onclick'=>"return hs.expand(this,{slideshowGroup:'gallery-highslide'})"));
		}}
	}